//=============================================================================
#include "CObjects.h"

//=============================================================================

CObject::CObject(){
}
CObject::CObject( int maxFrames, int height, int width, int X, int Y)
{

		this->Height = height;
		this->Width = width;
		this->X = X;
		this->Y = Y;
		this->maxFrames = maxFrames;
}

//=============================================================================
bool CObject::OnLoad(char* File, int Width, int Height, int MaxFrames) {
    if(CEntity::OnLoad(File, Width, Height, MaxFrames) == false) {
        return false;
    }

    return true;
}

//-----------------------------------------------------------------------------
void CObject::OnLoop() {
	
	CEntity::OnLoop();
}

//-----------------------------------------------------------------------------
void CObject::OnRender(SDL_Surface* Surf_Display) {
	CEntity::OnRender(Surf_Display);
}

//------------------------------------------------------------------------------
void CObject::OnCleanup() {
	CEntity::OnCleanup();
}

//------------------------------------------------------------------------------
void CObject::OnAnimate() {
	
	if(SpeedX != 0) {
		Anim_Control.MaxFrames = this->maxFrames;
	}else{
		Anim_Control.MaxFrames = 0;
	}

	CEntity::OnAnimate();
}

//=============================================================================
